<style type="text/css">
	#bannerAsd {display: none !important;}
	.em-header-style31 {margin: 0px;}
	.em-wrapper-main .container-main{margin: 0px;padding: 0px;width: 100%;}
	.em-main-container.em-col1-layout >div.row{margin: 0px;}
	.em-main-container.em-col1-layout >div.row >div.em-col-main{margin: 0px;}
	.em-main-container.em-col1-layout > div.row > div.em-col-main{margin:0px;padding:0px;}
</style>
<?php
//产品配置项
	$currentUrl = $this->helper('core/url')->getCurrentUrl();//当前活动链接	
	$home_url    =  Mage::getBaseUrl();
    $this_store  = Mage::app()->getStore()->getStoreId();//视图判断
    $skin_url    = $this->getSkinUrl();//当前皮肤路径
    $sf_advantage = ($this_store == '2') ? $skin_url.'images/landing-page/icod/ru/' : $skin_url.'images/landing-page/icod/en/';

/*获取产品*/
$data = Mage::helper('promoteevents')->getEvents('neolix_promotion_copywriting');
$productsImgSize = '190';
$product_sku_02 = $data->getProducts($productsImgSize);

/* slider config 页面id*/
$idJs = "em_minifilter_products_".md5(uniqid(rand()));    
if ($this->getData('slider_unique_id'))
$idJs = $this->getData('slider_unique_id');
$this->idJs = $idJs;
/*获取产品*/

?>

<!-- 活动倒计时 -->
<?php
	//配置活动时间段
	$begintime = $data->getEventsFromDate();
	$endtime   = $data->getEventsToDate();
	//echo $begintime.'<br/>';
	//echo $endtime.'<br/>';
	
	date_default_timezone_set("Etc/GMT-3");
	$nowTime  = date("Y-m-d H:i:s",time());
	//$begintime = "2016/09/18 12:00:00";
	
	$begintime = "2016-09-21 00:00:00";
	$endtime   = "2016/10/08 00:00:00";
?>
<script type="text/javascript">
//<![CDATA[
(function($){
        var page_endtime = '<div class="append_div"><div class="countdown_patry"><div class="countdown_patry_end"><div class="endtime"><div><p><?php echo $this->__("The Promotion Has Ended.") ?></p></div><div><h2><?php echo $this->__("Thanks For Your Attenyion.");  ?></h2></div><div class="endtime_submit"><a href="<?php echo Mage::getBaseUrl(); ?>"><?php echo $this->__("Continue Shopping"); ?></a></div></div></div></div></div>';
        var page_starttime = '<div class="append_div"><div class="countdown_patry"><div class="countdown_patry_time"><div class="countdown_span"><?php echo $this->__("Deal Start in:"); ?></div><div class="patry" ><div class="patry_s"><div id="RemainD">00</div><div class="text_party">:</div><div id="RemainH">00</div><div class="text_party">:</div><div id="RemainM">00</div><div class="text_party">:</div><div id="RemainS">00</div></div><div><div><?php echo $this->__("days"); ?></div><div></div><div><?php echo $this->__("hours")?></div><div></div><div><?php echo $this->__("minutes"); ?></div><div></div><div><?php echo $this->__("seconds"); ?></div></div></div></div></div></div>';

        var interval = "1000";
					var nowTime   = "<?php echo $nowTime ?>";
					var begintime = "<?php echo $begintime ?>";
					var endtime   = "<?php echo $endtime ?>";
					
					
					var nowTime    = new Date(nowTime);
					var starttime  = new Date(begintime);
					var endtimes   = new Date(endtime);
					
					
					
					if(starttime.getTime() > nowTime.getTime() ){
						$('body').append(page_starttime);
						window.setInterval(function(){ShowCountDown();}, interval);
					}
					if(nowTime.getTime() > endtimes.getTime()){
						$('body').append(page_endtime);
					}
					
					function ShowCountDown()
					{
						var starttime_seconds  = starttime.getTime();
						var nowtime_seconds    = nowTime.getTime();
						var leftTime   = starttime_seconds - nowtime_seconds;
						var leftsecond = parseInt(leftTime/1000);
						var day    = Math.floor(leftsecond/(60*60*24));
						var hour   = Math.floor((leftsecond-day*24*60*60)/3600);
						var minute = Math.floor((leftsecond-day*24*60*60-hour*3600)/60);
						var second = Math.floor(leftsecond-day*24*60*60-hour*3600-minute*60);
						if(day < 10){
							$("#RemainD").html('<span>0</span><span>'+day+'</span>');
						}else {
							$("#RemainD").html(day);
						}
						if(hour < 10){
							$("#RemainH").html('<span>0</span><span>'+hour+'</span>');
						}else {
							$("#RemainH").html(hour);
						}
						if(minute < 10){
							$("#RemainM").html('<span>0</span><span>'+minute+'</span>');
						}else {
							$("#RemainM").html(minute);
						}
						if(second <10 ){
							$("#RemainS").html('<span>0</span><span>'+second+'</span>');
						}else {
							$("#RemainS").html(second);
						}
						if(day == "0"  && hour == "0" && minute == "0" && second == "0" ){
							$('.append_div').remove();
						}
					}
})(jQuery);
//]]>
</script>
<!-- 活动倒计时 -->

<div class="sf_mine">
	<div class="sf_advantage">
		<ul>
			<li><img src="<?php echo $sf_advantage ?>New_3.png" alt=""></li>
			<li><img src="<?php echo $sf_advantage ?>New_4.png" alt=""></li>
			<li><img src="<?php echo $sf_advantage ?>New_5.png" alt=""></li>
			<li><img src="<?php echo $sf_advantage ?>New_6.png" alt=""></li>
			<li><img src="<?php echo $sf_advantage ?>New_7.png" alt=""></li>
			<li><img src="<?php echo $sf_advantage ?>New_8.png" alt=""></li>
			<li><img src="<?php echo $sf_advantage ?>New_9.png" alt=""></li>
		</ul>
	</div>
	<div class="wai" >
		<div class="shouji_bg">
			<div class="shouji_left"><a target="_blank" href="<?php echo $this->getBaseUrl().'neolix-hd-5-0-quad-core-2-16gb-4g-google-android-4-4-waterproof-smartphone';?>"></a></div>
				<div>
					<div class="shouji_right_up"><div class="coupon">NEOLIX-PRO</div></div>
					<div class="shouji_right_down"><iframe width="100%" height="100%" src="https://www.youtube.com/embed/wCMIR2ffL5E?rel=0" frameborder="0" allowfullscreen></iframe></div>
				</div>
		</div>
	</div>
	<div class="sf_background">
		<div class="sf_title"></div>
		<div class="sf_products">
		<div class="product_content">
		<?php if (!empty($product_sku_02)): ?>
			<?php foreach ($product_sku_02 as $val): ?>
				<?php foreach ($val as $_product): ?>
					<?php if (count($_product) > 0): ?>
						<div class="em-item-slider">
							<div class="products-grid">
							<div class="item first" style="width: 100%">
							<div class="product-item">
								<?php //Mage::helper('promoteevents')->isDisplayLabels($_product['id']); ?> 
								<div class="product-shop-top">
								<a target="_blank" href="<?php echo $productUrl = $_product['url'] ?>" title="<?php echo $productName = $_product['name'] ?>" class="product-image ">
									<img src="<?php echo $_product['thumbnail']; ?>" width="<?php echo $productsImgSize; ?>" alt="<?php echo $productName; ?>" />
								</a>
								<div class="em-element-display-hover bottom">          
									<ul class="add-to-links">
										<li><a href="<?php echo $_product['wishlist'] ?>" class="link-wishlist" title="<?php echo $this->__('Add to Wishlist') ?>"><?php echo $this->__('Add to Wishlist') ?></a></li>
									</ul>
								</div>
								</div>
								<div class="product-shop">
									<div class="f-fix">
										<!--product name-->
										<h3 class="product-name"><a target="_blank" href="<?php echo $productUrl; ?>" title="<?php echo $productName ?>"><?php echo $productName; ?></a></h3>
										<!--product price-->
										<?php 
											$price = $_product['price'];
											$currencyPrice = $_product['currency_price'];
											$finalPrice = $_product['final_price'];
											$currencyFinalPrice = $_product['currency_final_price'];
										?>
										<div class="product_price">
											<?php if ($price == $finalPrice): ?>
												<span class="price"><?php echo $currencyPrice; ?></span>
											<?php else : ?>
												<span class="prices"><?php echo $currencyPrice; ?></span>
												<span class="finalPrice"><?php echo $currencyFinalPrice; ?></span>
											<?php endif ?>
										</div>
										<!-- Current Stcok -->
										<div class="current_stcok">
											<!-- <span>
												<?php //echo $this->__('Qty.'); ?><?php //echo $_product['qty']; ?>
											</span> -->
											<?php if ($price!= $finalPrice): ?>
												<?php 
													$price_stk = ($price-$finalPrice)/$price;
													$price_stks = number_format($price_stk,2);
													echo (Mage::app()->getStore()->getStoreId() == '2')?"Скидка ".$price_stks*100 . "%":$price_stks*100 . "% off";
												?>
											<?php endif ?>
										</div>
										<!--Shop Now-->
										<div class="em-btn-addto">
											<a target="_blank" href="<?php echo $productUrl ?>"><?php echo $this->__('Shop Now') ?></a>
										</div>  
									</div>
								</div>
								<?php if($_product['qty'] == 0): ?>
									<div class="page_instock"></div>
								<?php endif ?>
							</div>
							</div>
							</div>
						</div>


					<?php endif ?>			
				<?php endforeach ?>
			<?php endforeach ?>
		<?php endif ?>
		</div>
		</div>
		
		<div class="sf_viewmore"><a target="_blank" href="<?php echo $this->getBaseUrl().'mobiles-telecoms/mobile-phones';?>"><?php echo $this->__('VIEW MORE >>');?></a></div>
		<div class="sf_bottom">
			<p style="margin-top: 10px;margin-bottom: 5px;"><?php echo $this->__('Rumall.com reserves the rights to the final explanation of the campaign.');?></p>
			<p><?php echo $this->__('Any questions regarding the campaign please email to service@rumall.com.');?></p>
		</div>
	</div>
</div>
	<!--分享链接-->
		<div id="addthis_one_key_share" style="position: fixed; top: 280px; right: 0px;">
			<ul>
			<li style="margin-bottom: 5px;"><a style="background-image: url('<?php echo $this->getSkinUrl('images/custom/addthis_share.png');?>'); background-position: 0px 0px; width: 32px; height: 32px; display: block;" href="https://api.addthis.com/oexchange/0.8/forward/vk/offer?url=<?php echo $currentUrl; ?>&amp;title=<?php //echo $_helper->productAttribute($_product, $_product->getName(), 'name') ?>"  target="_blank">&nbsp;</a></li>
			<li style="margin-bottom: 5px;"><a style="background-image: url('<?php echo $this->getSkinUrl('images/custom/addthis_share.png');?>'); background-position: 0px -37px; width: 32px; height: 32px; display: block;" href="https://api.addthis.com/oexchange/0.8/forward/odnoklassniki_ru/offer?url=<?php echo $currentUrl; ?>&amp;title=<?php //echo $_helper->productAttribute($_product, $_product->getName(), 'name') ?>" target="_blank">&nbsp;</a></li>
			<li style="margin-bottom: 5px;"><a style="background-image: url('<?php echo $this->getSkinUrl('images/custom/addthis_share.png');?>'); background-position: 0px -74px; width: 32px; height: 32px; display: block;" href="https://api.addthis.com/oexchange/0.8/forward/facebook/offer?url=<?php echo $currentUrl; ?>&amp;title=<?php //echo $_helper->productAttribute($_product, $_product->getName(), 'name') ?>" target="_blank">&nbsp;</a></li>
			</ul>
		</div>


